//
//  BuzzerEnableApi.m
//  AFNetworking
//
//  Created by Henry on 2023/7/26.
//

#import "BuzzerEnableApi.h"
@interface BuzzerEnableApi()

@property(nonatomic,copy)NSString *sn;
@property(nonatomic,copy)NSString *subThingTypeName;
@property(nonatomic,assign)BOOL enable;
@end
@implementation BuzzerEnableApi

-(id)initWithDevId:(NSString *)thingName withThingTypeName:(NSString *)thingTypeName withSN:(NSString *)sn withSubDeviceThingTypeName:(NSString *)subThingTypeName withEnable:(BOOL)enable{
    if(self = [super init]){
        self.thingName = thingName;
        self.thingTypeName = thingTypeName;
        self.sn = sn;
        self.subThingTypeName = subThingTypeName;
        self.enable = enable;
    }
    return self;
}


-(id)getTopic{
    return [NSString stringWithFormat:@"st/siterlink/%@/things/%@/to_dev",self.thingTypeName,self.thingName];
}

-(id)getCommandContent{
    return @{@"cmd":@6,@"sn":self.sn,@"dev_type":self.subThingTypeName};
}

-(id)getSubcribeTopic{
    return [NSString stringWithFormat:@"st/siterlink/%@/things/%@/from_dev",self.thingTypeName,self.thingName];
}



@end
